package test5;

import test5.editor.JavaEditorKit;
import test5.editor.WideCaret;

import javax.swing.*;
import java.awt.*;

/**
 * Created by Claudiu-Florin FILIMON
 * Date: Aug 4, 2007
 * Time: 12:42:17 PM
 * Revision: 0
 */
public class TestWindow extends JFrame
{
    private JEditorPane editorPane;
    private JavaEditorKit editorKit;

    public TestWindow()
    {
        editorPane = new JEditorPane();
        editorPane.setFont(new Font("Monospaced",Font.PLAIN, 12));
        editorKit = new JavaEditorKit();

        editorPane.setContentType(editorKit.getContentType());
        editorPane.setEditorKitForContentType(editorKit.getContentType(), editorKit);
        editorPane.setContentType(editorKit.getContentType());

//        editorPane.setCaret(new WideCaret());

        setSize(640,480);
        getContentPane().setLayout(new BorderLayout());

        getContentPane().add(editorPane, BorderLayout.CENTER);

        setDefaultCloseOperation(EXIT_ON_CLOSE);
        setVisible(true);
    }


    public static void main(String[] args)
    {
        new TestWindow();
    }
}
